
--建表脚本
CREATE TABLE [dbo].[limit_medication] (
    [code]        VARCHAR (150)  NULL,
    [name]        NVARCHAR (150) NULL,
    [type]        NVARCHAR (150) NULL,
    [reagentType] NVARCHAR (150) NULL,
    [limit]       NVARCHAR (150) NULL,
    [remark]      NVARCHAR (200) NULL,
    [nameAllEn]   VARCHAR (350)  NULL,
    [nameFirstEn] VARCHAR (350)  NULL,
    [id]          INT            IDENTITY (1, 1) NOT NULL,
    [category]    NVARCHAR (50)  NULL
);


CREATE TABLE [dbo].[sec_admin_user] (
    [id]        VARCHAR (50) NOT NULL,
    [user_name] VARCHAR (50) NULL,
    [password]  VARCHAR (50) NULL,
    [role]      VARCHAR (50) NULL,
    [valid]     VARCHAR (1)  NULL
);



CREATE TABLE [dbo].[three_medication_dir] (
    [code]               VARCHAR (200)  NULL,
    [name]               NVARCHAR (250) NULL,
    [type]               NVARCHAR (200) NULL,
    [payedGrade]         NVARCHAR (100) NULL,
    [price]              VARCHAR (100)  NULL,
    [unit]               NVARCHAR (100) NULL,
    [standard]           NVARCHAR (150) NULL,
    [reagentType]        NVARCHAR (150) NULL,
    [selfPercent]        VARCHAR (150)  NULL,
    [limitPrice]         VARCHAR (150)  NULL,
    [heightLimitPrice]   VARCHAR (150)  NULL,
    [provinceLimitPrice] VARCHAR (150)  NULL,
    [cityLimitPrice]     VARCHAR (150)  NULL,
    [countyLimitPrice]   VARCHAR (150)  NULL,
    [villageLimitPrice]  VARCHAR (150)  NULL,
    [bedPrice]           NVARCHAR (150) NULL,
    [remark]             NVARCHAR (MAX) NULL,
    [nameAllEn]          VARCHAR (200)  NULL,
    [nameFirstEn]        VARCHAR (100)  NULL,
    [id]                 INT            IDENTITY (1, 1) NOT NULL
);


---添加管理员用户脚本
INSERT INTO [dbo].[sec_admin_user] ([id], [user_name], [password], [role], [valid]) VALUES (N'3967acc06bfb40cc94e4079ffb15f318', N'user', N'e10adc3949ba59abbe56e057f20f883e', N'普通用户', N'1')
INSERT INTO [dbo].[sec_admin_user] ([id], [user_name], [password], [role], [valid]) VALUES (N'abv1233333', N'test', N'e10adc3949ba59abbe56e057f20f883e', N'普通用户', N'1')
INSERT INTO [dbo].[sec_admin_user] ([id], [user_name], [password], [role], [valid]) VALUES (N'be1bf47566714d55b0196ebec2bd90b0', N'admin', N'e10adc3949ba59abbe56e057f20f883e', N'管理员', N'1')

commit;